function mapChildren(children, func, context) {
    //TODO实现此mapChildren方法
    let value,
        childrenMap=[]
    children.forEach((item,index)=> {
        value= (Array.isArray(item)?recursionAry(item,index,func):func(item,index))
        childrenMap.push(...(Array.isArray(value)?value:""))
    })
    return childrenMap;
}
function recursionAry(item,index,func){
    let result = []
    item.forEach((r,i)=>{
       result.push(...(Array.isArray(r)?recursionAry(r,i,func):func(r,index+i))) 
    })
    return result
}
//2020/04/07  冯更更   childrenMap
export {
    mapChildren as map,
};